<?php
Yii::app()->clientScript->registerScript('flash_top','
    $(function(){
        $(".bxslider").bxSlider({
            captions: true,
            auto: true
        });
    })
',CClientScript::POS_BEGIN );
?>


<?php if($role){ ?>
<div  class="contextual-links-region" id="index-flash-setting-block">
    <div class="contextual-links-wrapper contextual-links-processed">
        <a href="#" class="contextual-links-trigger">配置</a>
        <ul class="contextual-links">
            <li class="views-ui-edit first">
                <a class="white fr manage-index-depict-setting" title="设置" data-code="index_depict_section" href="javascript:void(0);">
                    <i class="fa fa-code"></i></i>&nbsp;HTML
                </a>
            </li>
        </ul>
    </div>
<?php } ?>
    <ul class="bxslider"> <!-- 555*455 -->
        <li>
            <img src="<?php echo $staticsPath; ?>/images/01.jpg"/>

            <p style="background: none repeat scroll 0 0 #00829c;color: #98e8f8; position: absolute;bottom: 0;right: 0;line-height: 1.6em;text-align: center;padding: 37px 0 1%;width: 35%;top: 0;z-index: 999;font-weight: 400;font-size: 14px;">
                <span style="color: #fff;display: block;display: block;font-weight: 300;margin-bottom: 0.5em;font-size: 3em;">猴王望远</span>
                <small>
                    何为神仙何为天,<br/>
                    只把强权做等闲.<br/>
                    孪育仙石欺日月,<br/>
                    潇洒水帘洞天间.<br/>
                    ----张旺[美图]
                </small>
            </p>

        </li>
        <li>
            <img src="<?php echo $staticsPath; ?>/images/02.jpg"/>
            <p style="background: none repeat scroll 0 0 #00829c;color: #98e8f8; position: absolute;bottom: 0;right: 0;line-height: 1.6em;text-align: center;padding: 37px 0 1%;width: 35%;">
                <span>战天神</span>
                <small>
                    聚义群圣妖称王,<br/>
                    推倒凌霄魔中仙.<br/>
                    十万天兵若泥偶,<br/>
                    四大天王似轻烟.<br/>
                    相传千年齐天圣,<br/>
                    英雄只此敢当先.<br/>
                    ----张旺[美图]
                </small>
            </p>
        </li>
        <li>
            <img src="<?php echo $staticsPath; ?>/images/35.jpg"/>
            <p><span>二郎神</span>
                <small>
                    情浪深埋似锉锥,<br/>
                    凝望只曾向月辉.<br/>
                    谁晓巍峨丈夫泪,<br/>
                    无时不惦易章规.<br/>
                    苦心更比天律固,<br/>
                    锁妹胁众启甥威.<br/>
                    四心齐备勇武俱,<br/>
                    三界神气亦可摧.<br/>
                    ----张旺[美图]
                </small>
            </p>
        </li>
        <li>
            <a>
            <img src="<?php echo $staticsPath; ?>/images/41.jpg"/>
            <p>
                <span>女神</span>
                <small>
                    　　 自从炼就五色彩石 <br/>
                    　　曾把天孔补全， <br/>
                    　　把黑暗驱逐了一半 <br/>
                    　　向那天球外边； <br/>
                    　　在这优美的世界当中， <br/>
                    　　吹奏起无声的音乐雝融。<br/>
                    　　不知道月儿圆了多少回，<br/>
                    　　照着这生命底音波吹送。<br/>
                </small>
            </p>
            </a>
        </li>
    </ul>
<?php if($role){ ?>
    <script type="text/javascript">
        $(function(){
            $.getContextual("#index-flash-setting-block");
        });
        $(function () {

            $(".manage-index-flash-setting").live('click',function(){
                var _this = $(this);
                var section_code = _this.attr('data-code');
                var applybox = document.getElementById('manage_index_flash_setting');
                art.dialog({
                    zIndex: 10004,
                    title: '涂涂圈设置区块',
                    width: 600,
                    height: 450,
                    content: applybox,
                    id: 'manage-index-flash-setting-id',
                    lock: true,
                    okVal: '设置',
                    ok: function () {
                        var _ok = this;
                        var content = '';
                        var type = 3;
                        $.ajax({
                            url:"<?php echo Yii::app()->createUrl('manage/index/html') ?>",
                            type : 'POST',
                            dataType:'json',
                            data:{section_code:section_code,content:content,type:type},
                            beforeSend : function() {
                                art.dialog.Talert('<div id="message-loading">正在设置中ing...</div>',5,false);
                            },
                            success : function (data) {
                                if(data['status']==1){
                                    _ok.close();
                                    art.dialog.Talert('<div id="message-ok">'+data['message']+'</div>',1,false);
                                }else{
                                    art.dialog.Talert('<div id="message-error">'+data['message']+'</div>',1,false);
                                }
                            }
                        });
                    },
                    cancelVal: '关闭',
                    cancel: true //为true等价于function(){}
                });
            });
        });
    </script>
</div>
    <div id="manage_index_flash_setting" style="display: none;">
        <div style="width:600px;height:400px;float:left">
            <label for="ManageFlashContent" style="text-align: left;width: 50px;float:left">HTML</label>
            <div style="margin-left: 70px;">
               asddas
            </div>
        </div>
    </div>
<?php } ?>
